package cvo.chess.client.entities.armies;

public abstract class Piece {

	//The name of the piece is generally used for debug purpose
	private String name;
	
	public Piece()
	{
		//By Default use the Class-name of the Piece (ex "Pawn")
		this.name = this.getClass().getName().substring(
				this.getClass().getName().lastIndexOf('.')+1);
	}
	
	/**
	 * 
	 * @param name The name of the piece
	 */
	public Piece(String name){
		this.name = name;
	}
	
	@Override
	public String toString(){
		return this.name; 
	}
	
}
